/*
 * To change this license header, choose License Headers in Project Properties.
 * To change this template file, choose Tools | Templates
 * and open the template in the editor.
 */

package beans;

import javax.annotation.PostConstruct;
import javax.faces.bean.ManagedBean;
import javax.faces.bean.RequestScoped;

/**
 * ManagedBean encargado de controlar el Menu.
 * @author fbaena
 */
@ManagedBean
@RequestScoped
public class MenuBean {

    private String bTesoreria = "hidden";
    private String bSecretaria = "hidden";
    private String bDireccion = "hidden";
    
    public boolean Direccion = false;
    public boolean Secretaria = false;
    public boolean Tesoreria = false;

    @PostConstruct
    public void init() {
        if(Secretaria == true)
            setbSecretaria("visible");
        if(Tesoreria == true)
            setbTesoreria("visible");
        if(Direccion == true)
            setbDireccion("visible");
    }
    
    public String isbTesoreria() {
        return bTesoreria;
    }

    public void setbTesoreria(String bTesoreria) {
        this.bTesoreria = bTesoreria;
    }

    public String isbSecretaria() {
        return bSecretaria;
    }

    public void setbSecretaria(String bSecretaria) {
        this.bSecretaria = bSecretaria;
    }

    public String isbDireccion() {
        return bDireccion;
    }

    public void setbDireccion(String bDireccion) {
        this.bDireccion = bDireccion;
    }
    
    public void activarDireccion(){
        setbDireccion("visible");
    }
}
